﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="EnterPriseChangePassword.aspx.cs" Inherits="NJL.WebUsers.AdminEnterprise.EnterPriseChangePassword" %>
<%@ Register Src="../Controls/WUCUservisitorLeft.ascx" TagName="WUCUservisitorLeft" TagPrefix="uc3" %>
<%@ Register Src="../Controls/UCenterHeader.ascx" TagName="UCenterHeader" TagPrefix="uc4" %>
<%@ Register Src="../Controls/UcenterFooter.ascx" TagName="UcenterFooter" TagPrefix="uc5" %>
<%@ Register src="../Controls/WUCUserEnterPriseLeft.ascx" tagname="WUCUserEnterPriseLeft" tagprefix="uc1" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title></title>
    <link href="../Styles/base1.css" rel="stylesheet" type="text/css" />
    <link href="../Styles/manage.css" rel="stylesheet" type="text/css" />
    <script src="../Scripts/md5.js" type="text/javascript"></script>
    <script src="../Scripts/jquery-1.4.1.min.js" type="text/javascript"></script>
    <script type="text/javascript" language="javascript">
        function check() {

            var txtFirsthandPwd = document.getElementById("<%=txtFirsthandPwd.ClientID %>").value;
            var newpwd = document.getElementById("<%=txtNewPwd.ClientID %>").value; //新密码
            var txtConfirmPwd = document.getElementById("txtConfirmPwd").value;    //确认密码
            hidPwd = md5(newpwd);
            if (txtFirsthandPwd == "") {
                alert("请输入原始密码");
                return false;
            }
            if (newpwd == "") {
                alert("请输入新密码");
                return false;
            }
            if (newpwd.length < 6 | newpwd.length > 20) {
                alert("您输入的密码长度必须在6-20位之间");
                return false;
            }
            if (txtConfirmPwd == "") {
                alert("请输入确认新密码");
                return false;
            }
            if (txtConfirmPwd != newpwd) {
                alert("两次输入密码不一致，请重新输入");
                return false;
            }
            document.getElementById("<%=hidPwd.ClientID %>").value = md5(newpwd);
        }
    </script>
</head>
<body class="managebg">
    <form id="form1" runat="server">
    <uc4:UCenterHeader ID="UCenterHeader1" runat="server" />
    <div class="managecont02 cleanFlex">
        <!--右侧内容-->
        <div class="f_right manageRight" id="right">
            <!--位置-->
            <div class="place">
            <span>欢迎您：<%=UserName %>&nbsp;&nbsp;[<a href="/Logout.aspx" class="green">退出登陆</a>]</span>
                <p>
                    您现在的位置是&nbsp;<strong><a href="Default.aspx">用户中心</a></strong>&gt;&gt;<strong>密码安全</strong></p>
            </div>
            <!--基本信息内容-->
            <div class="cleanFlex m_top_10">
            </div>
            <div>
                <!--标题-->
                <div class="">
                    <ul class="titleTabmanage">
                        <li class="now">
                            <p>
                                <a href="#">修改密码</a></p>
                        </li>
     
                    </ul>
                </div>
                <div class="cont">
                    <!--修改密码-->
                    <table cellpadding="0" cellspacing="0" class="tab m_top_10">
                        <tr>
                            <td width="169" class="left">
                                原始密码：
                            </td>
                            <td width="255">
                                <asp:TextBox ID="txtFirsthandPwd" runat="server" MaxLength="20" class="input" 
                                    Style="width: 175px;" TextMode="Password"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td class="left">
                                新密码：
                            </td>
                            <td>
                                <asp:TextBox ID="txtNewPwd" runat="server" MaxLength="20" class="input" 
                                    Style="width: 175px;" TextMode="Password"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td class="left">
                                确认新密码：
                            </td>
                            <td>
                                <asp:TextBox ID="txtConfirmPwd" MaxLength="20" runat="server" class="input" 
                                    Style="width: 175px;" TextMode="Password"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td colspan="2" class="bottom">
                                <asp:Button ID="btnSumbit" runat="server" Text="保存" OnClick="btnSumbit_Click" OnClientClick="return check()"
                                    class="redbtn" />
                            </td>
                        </tr>
                    </table>
                    <!--密码保护问题-->
                    <table cellpadding="0" cellspacing="0" class="tab m_top_10" style="display:none">
                        <tr>
                            <td class="left" width="169">
                                密码保护问题
                            </td>
                            <td width="255">
                                <input type="text" class="input" style="width: 175px;" />
                            </td>
                        </tr>
                        <tr>
                            <td class="left" width="169">
                                问题答案
                            </td>
                            <td>
                                <input type="text" class="input" style="width: 175px;" />
                            </td>
                        </tr>
                        <tr>
                            <td colspan="2" class="bottom">
                                <input type="button" value="保 存" class="redbtn" />
                            </td>
                        </tr>
                    </table>
                </div>
                <!--我的游记-->
                <div>
                </div>
            </div>
        </div>
      <uc1:WUCUserEnterPriseLeft ID="WUCUserEnterPriseLeft1" runat="server" />
        <div class="managecontbottom">
        </div>
    </div>
    <asp:HiddenField ID="hidPwd" runat="server" />
    
    <uc5:UcenterFooter ID="UcenterFooter1" runat="server" />
    </form>
</body>
</html>